package homework;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.stream.Collector;
import java.util.stream.Collectors;

public class homework06 {
public static void main(String[] args) {
	ArrayList<Integer> list = new ArrayList<>();
	Collections.addAll(list, 1,1,2,22,2,3,4,4,3,5);
	System.out.println(quchong(list));
}

private static List quchong(ArrayList<Integer> list) {
	List<Integer> list1 = list.stream().distinct().collect(Collectors.toList());
	return list1;
	// TODO Auto-generated method stub
	
}
}
